package com.htsc.mrp.dao.impl;

import com.htsc.mrp.dao.IGeneratorDao;
import com.htsc.mrp.po.Generator;
import com.htsc.mrp.dao.BaseDao;
import org.springframework.stereotype.Repository;
import tk.mybatis.spring.annotation.MapperScan;

/**
 * @author K0890042
 * @date 2019/3/20 15:36
 * @description: Htsc.com Inc. Copyright (c) 2004-2019 All Rights Reserved.
 */
@Repository
public class GeneratorDao extends BaseDao implements IGeneratorDao {
    @Override
    public int deleteByPrimaryKey(Integer id) {
        return delete("GeneratorMapper.deleteByPrimaryKey", id);
    }

    @Override
    public int insert(Generator record) {
        return insert("GeneratorMapper.insert", record);
    }

    @Override
    public int insertSelective(Generator record) {
        return insert("GeneratorMapper.insertSelective", record);
    }

    @Override
    public Generator selectByPrimaryKey(Integer id) {
        return selectByPrimaryKey(id);
    }

    @Override
    public int updateByPrimaryKeySelective(Generator record) {
        return update("GeneratorMapper.updateByPrimaryKeySelective", record);
    }

    @Override
    public int updateByPrimaryKey(Generator record) {
        return update("GeneratorMapper.updateByPrimaryKey", record);
    }

    @Override
    public String selectLastVersionByFileName(String filename) {
        return selectLastVersionByFileName(filename);
    }
}
